Re: [PATCH] staging: csr: remove a number of unneeded includes of version.h

2012-10-23 Thread Jesper Juhl
On Mon, 22 Oct 2012, Greg Kroah-Hartman wrote: > On Thu, Oct 18, 2012 at 09:51:56PM +0200, Jesper Juhl wrote: > > > > Signed-off-by: Jesper Juhl > > Someone already beat you to this patch, sorry. > Heh. That happens - no problem - as long as it gets fixed :) --

Re: [PATCH v2] Documentation DMA-API-HOWTO.txt Add dma mapping error check usage examples

2012-10-18 Thread Jesper Juhl
map all mapped buffers when > + mapping error is detected in the middle) > + "... if buffers are allocated in a loop..." -- Jesper Juhlhttp://www.chaosbits.net/ Don't top-post http://www.catb.org/jargon/html/T/top-post.html Plain text mails only, please. __

[PATCH] staging: csr: remove a number of unneeded includes of version.h

2012-10-18 Thread Jesper Juhl
Signed-off-by: Jesper Juhl --- drivers/staging/csr/csr_framework_ext.c|1 - drivers/staging/csr/csr_time.c |1 - drivers/staging/csr/io.c |1 - drivers/staging/csr/monitor.c |1 - drivers/staging/csr/netdev.c |1

[PATCH] Staging: silicom: Fix up version.h includes

2012-10-18 Thread Jesper Juhl
drivers/staging/silicom/bypasslib/bplibk.h actually uses stuff from version.h so it should include the header. drivers/staging/silicom/bp_proc.c and drivers/staging/silicom/bypasslib/bypass.c currently include the header but use nothing from it so they don't need to. Signed-off-by: Jesper

[PATCH] staging: remove version.h include from dgrp/dgrp_sysfs.c

2012-10-18 Thread Jesper Juhl
The file uses nothing from linux/version.h, so the include is pointless - remove it. Signed-off-by: Jesper Juhl --- drivers/staging/dgrp/dgrp_sysfs.c |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/drivers/staging/dgrp/dgrp_sysfs.c b/drivers/staging/dgrp/dgrp_sysfs.c

Re: [PATCH] staging: rtl8192e: remove casting of returned pointer from kmalloc

2012-09-06 Thread Jesper Juhl
ew_crypt = kmalloc(sizeof(*new_crypt), GFP_KERNEL); > if (new_crypt == NULL) { > ret = -ENOMEM; > goto done; > Looks correct to me. Reviewed-by: Jesper Juhl -- Jesper Juhlhttp://www.chaosbits.net/ Don't

Re: [PATCH 3/4] staging: csr: fix coding style issue in new_coredump_node

2012-08-15 Thread Jesper Juhl
newnode->zone[i] = NULL; > + } > + } > > -/* Link to previous node */ > -newnode->prev = prevnode; > - if (prevnode) > -{ > -prevnode->next = newnode; > -} > -newnode->next = NULL; >

Re: [PATCH 1/4] staging: csr: fix the coding style problems

2012-08-15 Thread Jesper Juhl
csrResult); > + return -EIO; > + } > > -return 0; > + return 0; > } /* uf_sdio_load() */ > > > @@ -1161,6 +1163,6 @@ uf_sdio_load(void) > void __exit > uf_sdio_unload(void) > { > -CsrSdioFunctionDriverUnregister(&unifi_sdioFu

[PATCH] staging: csr: Fix up version.h includes

2012-08-10 Thread Jesper Juhl
Include version.h where actually needed, remove where unneeded. Signed-off-by: Jesper Juhl --- drivers/staging/csr/csr_panic.c| 1 - drivers/staging/csr/drv.c | 3 +-- drivers/staging/csr/io.c | 2 +- drivers/staging/csr/monitor.c | 3

Re: [PATCH] staging:ccg: Fix missing brackets for sizeof (found by sparse).

2012-08-08 Thread Jesper Juhl
gt; struct fsg_common *common; > int err; > > - memset(&fsg, 0, sizeof fsg); > + memset(&fsg, 0, sizeof(fsg)); > fsg.nluns = 1; > fsg.luns[0].removable = 1; > fsg.vendor_name = iManufacturer; > Looks good to me. Reviewed-by: Jesper Juhl

[PATCH] staging: speakup: i18n.c: Fix leak in msg_set()

2012-08-07 Thread Jesper Juhl
If we end up returning -EINVAL from the function we will leak the memory allocated to 'newstr' which has been allocated but not yet assigned to anything. Fix the leak by properly freeing the memory again before we return. Signed-off-by: Jesper Juhl --- drivers/staging/speakup/i18n.

[PATCH 5/5] staging: vt6656: remove commented out stuff from hostap.c

2012-07-26 Thread Jesper Juhl
Git has the code if we ever need it, so instead of having chunks of commented out code clutter up the file get rid of it. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/hostap.c | 45 + 1 file changed, 1 insertion(+), 44 deletions(-) diff --git

[PATCH 3/5] staging: vt6656: Fix indentation in hostap.c

2012-07-26 Thread Jesper Juhl
We use tabs for indentation, not spaces. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/hostap.c | 644 +++- 1 file changed, 301 insertions(+), 343 deletions(-) diff --git a/drivers/staging/vt6656/hostap.c b/drivers/staging/vt6656/hostap.c index

[PATCH 4/5] staging: vt6656: minor trivial whitespace cleanups

2012-07-26 Thread Jesper Juhl
Convert a few tabs to spaces, remove some pointless whitespace, add some missing whitespace (in drivers/staging/vt6656/hostap.c). All quite small and trivial. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/hostap.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff

[PATCH 2/5] staging: vt6656: Remove some redundant blank lines from hostap.c

2012-07-26 Thread Jesper Juhl
This trivial patch simply removes some completely redundant blank lines from drivers/staging/vt6656/hostap.c Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/hostap.c | 40 1 file changed, 40 deletions(-) diff --git a/drivers/staging/vt6656

[PATCH 1/5] staging: vt6656: don't leak 'param' in vt6656_hostap_ioctl() when returning -EOPNOTSUPP

2012-07-26 Thread Jesper Juhl
Don't return -EOPNOTSUPP directly in switch case's since it'll leak the memory allocated to 'param' when that variable goes out of scope without having been assigned to anything. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/hostap.c | 12 ++-- 1 file ch

[PATCH 0/5] staging: vt6656: small bug fixes and cleanups for hostapd.c

2012-07-26 Thread Jesper Juhl
Hi Greg Here's a small series of patches that fixes some memory leaks and cleans up the code a bit for vt6656 hostapd.c - done on top of Linus' tree as of today. -- Jesper Juhlhttp://www.chaosbits.net/ Don't top-post http://www.catb.org/jargon/html/T/top-post.html P

Re: [PATCH 1/2] Staging: slicoss: Clean up tabs vs spaces in slic.h

2012-07-23 Thread Jesper Juhl
On Mon, 23 Jul 2012, Dan Carpenter wrote: > On Sun, Jul 22, 2012 at 10:57:09PM +0200, Jesper Juhl wrote: > > Make it match CodingStyle a bit better, tab/space wise. > > > > Signed-off-by: Jesper Juhl > > --- > > dri

[PATCH 2/2] Staging: slicoss: Clean up spaces vs tabs in slicoss.c

2012-07-22 Thread Jesper Juhl
Make it match CodingStyle a bit better, space/tab wise. Signed-off-by: Jesper Juhl --- drivers/staging/slicoss/slicoss.c | 809 +++--- 1 file changed, 397 insertions(+), 412 deletions(-) diff --git a/drivers/staging/slicoss/slicoss.c b/drivers/staging/slicoss

[PATCH 1/2] Staging: slicoss: Clean up tabs vs spaces in slic.h

2012-07-22 Thread Jesper Juhl
Make it match CodingStyle a bit better, tab/space wise. Signed-off-by: Jesper Juhl --- drivers/staging/slicoss/slic.h | 751 - 1 file changed, 374 insertions(+), 377 deletions(-) diff --git a/drivers/staging/slicoss/slic.h b/drivers/staging/slicoss

Re: [PATCH 1/3] staging: vt6656: iwctl: fix up spacing around operators

2012-07-08 Thread Jesper Juhl
On Sun, 8 Jul 2012, Joe Perches wrote: > On Mon, 2012-07-09 at 00:58 +0200, Jesper Juhl wrote: > > A few cases were missed in my previous cleanup, this takes care of the > > last cases of missing space (or too much space (as in a newline)) > > around operators ('='

Re: [PATCH 3/3] staging: vt6656: iwctl: remove a few remaining redundant newlines

2012-07-08 Thread Jesper Juhl
On Sun, 8 Jul 2012, Joe Perches wrote: > On Mon, 2012-07-09 at 00:59 +0200, Jesper Juhl wrote: > > I missed a few redundant newlines the first time. > [] > > diff --git a/drivers/staging/vt6656/iwctl.c b/drivers/staging/vt6656/iwctl.c > [] > > @@ -964,7 +964,6

[PATCH 3/3] staging: vt6656: iwctl: remove a few remaining redundant newlines

2012-07-08 Thread Jesper Juhl
I missed a few redundant newlines the first time. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/staging/vt6656/iwctl.c b/drivers/staging/vt6656/iwctl.c index 13ad62c..8b9894b 100644 --- a/drivers

[PATCH 2/3] staging: vt6656: iwctl: Fix up a few remaining brace issues

2012-07-08 Thread Jesper Juhl
My previous cleanup patches missed a few cases of redundant/missing/replaced curly braces. This should fix up the last ones. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 23 +++ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/drivers

[PATCH 1/3] staging: vt6656: iwctl: fix up spacing around operators

2012-07-08 Thread Jesper Juhl
A few cases were missed in my previous cleanup, this takes care of the last cases of missing space (or too much space (as in a newline)) around operators ('=', '==', ',', '<'). Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 13 ++

[PATCH 0/3][v2] staging: vt6656: iwctl: mop up a few remaining obvious style issues.

2012-07-08 Thread Jesper Juhl
series is on top of linux-next (next-20120706). -- Jesper Juhlhttp://www.chaosbits.net/ Don't top-post http://www.catb.org/jargon/html/T/top-post.html Plain text mails only, please. ___ devel mailing list devel@linuxdriverproject.org

Re: [PATCH] staging: vt6656: iwctl: mop up a few remaining obvious style issues

2012-07-06 Thread Jesper Juhl
On Fri, 6 Jul 2012, Greg Kroah-Hartman wrote: > On Wed, Jun 27, 2012 at 09:19:15PM +0200, Jesper Juhl wrote: > > My previous 14 patch series to vt6656 missed a few bits and > > pieces. This mops up the last few obvious style issues. > > It is quite short and completely trivi

[PATCH] Staging: echo: One variable per line

2012-06-27 Thread Jesper Juhl
Our convention is one (statement and) variable per line. Enforce this in drivers/staging/echo/echo.[ch] . Signed-off-by: Jesper Juhl --- drivers/staging/echo/echo.c | 9 ++--- drivers/staging/echo/echo.h | 28 2 files changed, 26 insertions(+), 11 deletions

[PATCH 7/7] staging: vt6656: int.c: correct indentation to use tabs rather than spaces

2012-06-27 Thread Jesper Juhl
Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/int.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/staging/vt6656/int.c b/drivers/staging/vt6656/int.c index e9fab45..eba4b50 100644 --- a/drivers/staging/vt6656/int.c +++ b/drivers/staging

[PATCH 6/7] staging: vt6656: int.c: We don't use spaces between a cast and the variable being converted

2012-06-27 Thread Jesper Juhl
Remove spaces between casts and variables from drivers/staging/vt6656/int.c . Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/int.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/staging/vt6656/int.c b/drivers/staging/vt6656/int.c index

[PATCH 5/7] staging: vt6656: int.c: Use one space between variable type and name

2012-06-27 Thread Jesper Juhl
The style of most kernel code is that there is 1 *space* between the type of a variable and its name. This patch enforces that in drivers/staging/vt6656/int.c . Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/int.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a

[PATCH 4/7] staging: vt6656: int.c: Remove unneeded cast

2012-06-27 Thread Jesper Juhl
When assigning a void* to a variable , the value is cast implicitly - there's no need for explicit cast. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/int.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/vt6656/int.c b/drivers/staging/vt6656/

[PATCH 3/7] staging: vt6656: int.c: Put comment about DEBUG print define on same line as code

2012-06-27 Thread Jesper Juhl
A small comment at the end of the line, mentioning the debug level, is enough - no need to repeat the entire line of code just for that. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/int.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/staging/vt6656/int.c

[PATCH 2/7] staging: vt6656: int.h: Fix indentation and spacing

2012-06-27 Thread Jesper Juhl
We use tabs for indentation and once space between variable types and variable name. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/int.h | 42 +- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/drivers/staging/vt6656/int.h b

[PATCH 1/7] staging: vt6656: int: Redundant blank line removal

2012-06-27 Thread Jesper Juhl
This trivial cleanup patch removes some completely redundant blank lines from drivers/staging/vt6656/int.[ch] Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/int.c | 4 drivers/staging/vt6656/int.h | 1 - 2 files changed, 5 deletions(-) diff --git a/drivers/staging/vt6656/int.c b

Re: [PATCH] Staging: vt6656: int.c: A few trivial style cleanups

2012-06-27 Thread Jesper Juhl
On Mon, 25 Jun 2012, Greg Kroah-Hartman wrote: > On Sun, Jun 24, 2012 at 10:12:12PM +0200, Jesper Juhl wrote: > > Removed a pointless cast + some whitespace cleanups. > > Please break this up into different patches as you are doing multiple > things. > Sure thing. A 7 pat

[PATCH] staging: vt6656: iwctl: mop up a few remaining obvious style issues

2012-06-27 Thread Jesper Juhl
My previous 14 patch series to vt6656 missed a few bits and pieces. This mops up the last few obvious style issues. It is quite short and completely trivial - simply deletes a few blank lines, does some whitespace cleanup around operators and adds a few curly braces. Signed-off-by: Jesper Juhl

[PATCH 14/14] staging: vt6656: iwctl: Clean up braces on 'if' statements

2012-06-24 Thread Jesper Juhl
Clean up braces on 'if' statements to (mostly) match coding style. A few other bits, like removing a few blank lines and such may have snug in. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 145 + 1 file changed, 61 inserti

[PATCH 11/14] staging: vt6656: iwctl: comment cleanup

2012-06-24 Thread Jesper Juhl
All comments now have one space between the code they follow and the comment start chars and one space after the comment start chars and the comment text. Also cleaned up some spacing within comments - mostly removed space before ':' and added space after ',' etc. Signed

[PATCH 13/14] staging: vt6656: iwctl: Cleanup spacing around operators (mostly)

2012-06-24 Thread Jesper Juhl
This cleans up spacing around operators according to CodingStyle. (A few deletions of empty lines that were missed by a previous patch are also included. A few bits and pieces broken on multiple lines were put one one line as well). Signed-off-by: Jesper Juhl --- drivers/staging/vt6656

[PATCH 10/14] staging: vt6656: iwctl: space after if/for/while/switch

2012-06-24 Thread Jesper Juhl
Our coding style dictates a space after if/for/while/switch and the opening parenthesis. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 144 - 1 file changed, 72 insertions(+), 72 deletions(-) diff --git a/drivers/staging/vt6656/iwctl.c

[PATCH 12/14] staging: vt6656: iwctl: one statement per line (if)

2012-06-24 Thread Jesper Juhl
Statement following 'if' should be on its own line. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/vt6656/iwctl.c b/drivers/staging/vt6656/iwctl.c index c639a3c..dd3c1ac 100644 ---

[PATCH 09/14] staging: vt6656: iwctl: remove spaces between casts and variables

2012-06-24 Thread Jesper Juhl
We do not usually write a space between a cast and the variable being converted. this patch removes such spaces where they occour in iwctl.c Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 148 - 1 file changed, 74 insertions(+), 74

[PATCH 08/14] staging: vt6656: iwctl: remove unneeded scope block in iwctl_siwessid()

2012-06-24 Thread Jesper Juhl
Reduce indentation by removing completely redundant scope block in the iwctl_siwessid() function. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 71 -- 1 file changed, 34 insertions(+), 37 deletions(-) diff --git a/drivers/staging/vt6656

[PATCH 07/14] staging: vt6656: iwctl: remove redundant cast (to PSDevice)

2012-06-24 Thread Jesper Juhl
netdev_priv() returns a void*, so there is no reason to explicitly cast to (PSDevice) when assigning to a variable of type PSDevice. The cast is done implicitly. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 58 +- 1 file changed, 29

[PATCH 05/14] staging: vt6656: iwctl: Fix up variable declarations (whitespace and 'one-per-line')

2012-06-24 Thread Jesper Juhl
Ensure that we have only one variable declaration per line and for each of those lines we have one space between type and variable name and if there's assignment, then we have one space on each side of the equals sign (and no more than 80 characters per line). Signed-off-by: Jesper

[PATCH 06/14] staging: vt6656: iwctl: ensure one space between defined name and value

2012-06-24 Thread Jesper Juhl
Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/vt6656/iwctl.c b/drivers/staging/vt6656/iwctl.c index 9fc9059..218e146 100644 --- a/drivers/staging/vt6656/iwctl.c +++ b/drivers/staging/vt6656

[PATCH 04/14] staging: vt6656: iwctl: remove redundant ';'

2012-06-24 Thread Jesper Juhl
else clauses don't need to be terminated with ';'. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/vt6656/iwctl.c b/drivers/staging/vt6656/iwctl.c index 7618fb9..ca4e7f0 10064

[PATCH 02/14] staging: vt6656: iwctl: fix up function declarations/prototypes

2012-06-24 Thread Jesper Juhl
indented by two tabs. Besides getting rid of the current tabs vs spaces mess it also shortens the files quite a bit and puts them more in line with most other kernel files. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 197 +++ drivers/staging/vt6656

[PATCH 01/14] staging: vt6656: iwctl: Remove redundant blank lines

2012-06-24 Thread Jesper Juhl
There are a number of excessive blank lines in iwctl.c - this patch gets rid of most of those that I personally considered the most obvious ones. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 76 -- 1 file changed, 76 deletions(-) diff

[PATCH 0/14][v2] staging: vt6656: Style cleanup of iwctl

2012-06-24 Thread Jesper Juhl
Here's a second attempt at a style cleanup of drivers/staging/vt6656/iwctl.[ch]. This time broken into a series of patches rather than the monster 3000+ line patch that I previously submitted (thanks Dan for setting me straight). Hopefullt this will be more reviewable :-) -- Jesper

Re: [PATCH] staging: vt6656: Style cleanup of iwctl

2012-06-24 Thread Jesper Juhl
On Sun, 24 Jun 2012, Dan Carpenter wrote: > On Sun, Jun 24, 2012 at 09:45:58PM +0200, Jesper Juhl wrote: > > Clean up the files iwctl.c and iwctl.h to match the official > > CodingStyle a bit more closely. > > > > This is *not* a complete cleanup, but it brings the f

[PATCH] Staging: vt6656: int.c: A few trivial style cleanups

2012-06-24 Thread Jesper Juhl
Removed a pointless cast + some whitespace cleanups. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/int.c | 52 drivers/staging/vt6656/int.h | 43 ++-- 2 files changed, 45 insertions(+), 50 deletions(-) Note

[PATCH] staging: vt6656: Correct a few assignments to be compares in iwctl_siwencodeext()

2012-06-21 Thread Jesper Juhl
p; (param->u.wpa_key.key_index == 1)) ... There are a 3 such mistakes in the iwctl_siwencodeext() function. This patch fixes them all. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/iwctl.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) The file could also do with

Re: [PATCH 00/13] drivers: hv: kvp

2012-06-21 Thread Jesper Juhl
n't this somehow be done once and for all in a distro neutral way? Just asking :-) -- Jesper Juhlhttp://www.chaosbits.net/ Don't top-post http://www.catb.org/jargon/html/T/top-post.html Plain text mails only, please. ___ devel mailing

[PATCH][Trivial] staging: rts5139: Remove duplicate include of rts51x.h

2012-06-21 Thread Jesper Juhl
The header "rts51x.h" is included unconditionally at the start of the file and then again once more under "#ifdef SUPPORT_FILE_OP". Once is enough, so remove the conditional include and just keep the unconditional one. Signed-off-by: Jesper Juhl --- drivers/staging/rts5

Re: [PATCH NEXT]staging: rtl8192u Fix typos.

2012-04-30 Thread Jesper Juhl
On Mon, 30 Apr 2012, Justin P. Mattock wrote: > On 04/30/2012 01:41 PM, Jesper Juhl wrote: > > On Mon, 30 Apr 2012, Justin P. Mattock wrote: > > > > > From: "Justin P. Mattock" > > > > > > Signed-off-by: Justin P. Mattock > > > &

Re: [PATCH NEXT]staging: rtl8192u Fix typos.

2012-04-30 Thread Jesper Juhl
> - // TODO: we should not delay such a long time. Ask help from SD3 > + // TODO: we should not delay such a long time. Ask help from SD3 How about "Ask for help" rather than "Ask help" ? > msleep(1); > > ret = rtl8192_QueryBBReg(dev, pPhyReg->rfLSSIR

Re: [PATCH 2/3] staging: vt6656: remove redundant parentheses from ioctl.c

2012-04-26 Thread Jesper Juhl
On Tue, 24 Apr 2012, Greg Kroah-Hartman wrote: > On Sat, Apr 21, 2012 at 10:04:37PM +0200, Jesper Juhl wrote: > > I seriously doubt that anyone is confused about the precedence rules > > for "*" and "+" - remove redundant extra parentheses. > > You neve

Re: [PATCH 3/3] staging: olpc_dcon.c: Remove a few spaces between casts and variables

2012-04-21 Thread Jesper Juhl
On Sat, 21 Apr 2012, Dan Carpenter wrote: > On Sat, Apr 21, 2012 at 08:33:15PM +0200, Jesper Juhl wrote: > > Just a trivial style cleanup. > > > > Signed-off-by: Jesper Juhl > > --- > > drivers/staging/olpc_dcon/olpc_dcon.c |8 > > 1 fil

[PATCH 3/3] staging: vt6656: trivial whitespace cleanups to ioctl.c

2012-04-21 Thread Jesper Juhl
This removes a space between a cast and the variable and makes the case statements in the switch stylewise consistent as to whether there's a blank line before each 'case' or not. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/ioctl.c |4 +++- 1 file changed, 3 i

[PATCH 2/3] staging: vt6656: remove redundant parentheses from ioctl.c

2012-04-21 Thread Jesper Juhl
I seriously doubt that anyone is confused about the precedence rules for "*" and "+" - remove redundant extra parentheses. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/ioctl.c |8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/st

[PATCH 1/3] staging: vt6656: Remove redundant casts from ioctl.c

2012-04-21 Thread Jesper Juhl
Remove some unneeded explicit casts from drivers/staging/vt6656/ioctl.c Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/ioctl.c | 20 +--- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/drivers/staging/vt6656/ioctl.c b/drivers/staging/vt6656/ioctl.c index

[PATCH 0/3][Trivial] staging: vt6656: Remove some redundant casts and parentheses + other style cleanups

2012-04-21 Thread Jesper Juhl
This is a resubmit (as a small series) of a patch I submitted on Mon, 16 Apr 2012 with subject "[PATCH][Trivial] staging: vt6656: Remove some redundant casts and parentheses + other style cleanups". Feedback from Joe Perches has been addresed in this series. -- Jesper Juhl

[PATCH 3/3] staging: olpc_dcon.c: Remove a few spaces between casts and variables

2012-04-21 Thread Jesper Juhl
Just a trivial style cleanup. Signed-off-by: Jesper Juhl --- drivers/staging/olpc_dcon/olpc_dcon.c |8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/staging/olpc_dcon/olpc_dcon.c b/drivers/staging/olpc_dcon/olpc_dcon.c index 7fe6eb6..992275c 100644 --- a

[PATCH 2/3] staging: olpc_dcon.c: Add missing level to a printk()

2012-04-21 Thread Jesper Juhl
Signed-off-by: Jesper Juhl --- drivers/staging/olpc_dcon/olpc_dcon.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/olpc_dcon/olpc_dcon.c b/drivers/staging/olpc_dcon/olpc_dcon.c index 862dbb5..7fe6eb6 100644 --- a/drivers/staging/olpc_dcon/olpc_dcon.c

[PATCH 1/3] staging: olpc_dcon.c: strings printed with printk() put on a single line

2012-04-21 Thread Jesper Juhl
Quoted strings that were broken over multiple lines are put on a single line for easier grep'ability. Signed-off-by: Jesper Juhl --- drivers/staging/olpc_dcon/olpc_dcon.c | 19 +-- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/drivers/staging/olpc

[PATCH 0/3] staging: olpc_dcon.c: checkpatch.pl and style fixups

2012-04-21 Thread Jesper Juhl
and variables Just a trivial style cleanup. -- Jesper Juhlhttp://www.chaosbits.net/ Don't top-post http://www.catb.org/jargon/html/T/top-post.html Plain text mails only, please. ___ devel mailing list devel@linuxdriverprojec

Re: [PATCH] staging: olpc_dcon.c: checkpatch.pl and style fixups

2012-04-18 Thread Jesper Juhl
On Wed, 18 Apr 2012, Greg Kroah-Hartman wrote: > On Sun, Apr 15, 2012 at 11:39:32PM +0200, Jesper Juhl wrote: [...] > > > > How's this? > > Not good, it still does more than one thing at once, please break up > into individual parts and resend. > Right you

Re: [PATCH 2/2] staging:android:fix line over 80 characters issue in binders.c this patch fixes line over 80 characters warning that was found using checkpatch.pl tool Signed-off-by:Anirudh Bhat

2012-04-18 Thread Jesper Juhl
On Thu, 19 Apr 2012, Jesper Juhl wrote: > On Wed, 18 Apr 2012, anirudh bhat wrote: > > > From: anirudh bhat > > > Unless you are sending a patch on behalf of someone else, and need to > preserve that person as the author of the patch, there's usually no need >

Re: [PATCH 2/2] staging:android:fix line over 80 characters issue in binders.c this patch fixes line over 80 characters warning that was found using checkpatch.pl tool Signed-off-by:Anirudh Bhat

2012-04-18 Thread Jesper Juhl
see that it says "static const char * array should probably be static const char * const" But you changed it to "static const char *const". A quick check for usage of the two forms: [jj@arch linux]$ git grep -E "static +const +char *\* +const" | wc -l 673 [jj@arch li

Re: [PATCH][Trivial] staging: vt6656: Remove some redundant casts and parentheses + other style cleanups

2012-04-18 Thread Jesper Juhl
On Tue, 17 Apr 2012, Joe Perches wrote: > On Mon, 2012-04-16 at 23:20 +0200, Jesper Juhl wrote: > > This is just a small/trivial cleanup patch. It makes the following > > changes to drivers/staging/vt6656/ioctl.c: > > > > 1. Remove some redundant casts. > > d

[PATCH][Trivial] staging: vt6656: Remove some redundant casts and parentheses + other style cleanups

2012-04-16 Thread Jesper Juhl
statements have a empty line between break; and the next case:. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/ioctl.c | 17 + 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/drivers/staging/vt6656/ioctl.c b/drivers/staging/vt6656/ioctl.c index d59456c..8295335

Re: [PATCH] staging: olpc_dcon.c: checkpatch.pl and style fixups

2012-04-15 Thread Jesper Juhl
On Sat, 14 Apr 2012, Andres Salomon wrote: > On Sun, 15 Apr 2012 00:53:04 +0200 (CEST) > Jesper Juhl wrote: > > > This patch removes the few checkpatch.pl issues that are currently > > reported for this file. > > > > It makes these changes: > > >

[PATCH] staging: olpc_dcon.c: checkpatch.pl and style fixups

2012-04-14 Thread Jesper Juhl
seemed trivial enough to just do as one patch, but I can split it if wanted. Signed-off-by: Jesper Juhl --- drivers/staging/olpc_dcon/olpc_dcon.c | 33 - 1 file changed, 16 insertions(+), 17 deletions(-) diff --git a/drivers/staging/olpc_dcon/olpc_dcon.c b/d

Re: [PATCH] staging: vt6656: Don't leak memory in drivers/staging/vt6656/ioctl.c::private_ioctl()

2012-04-11 Thread Jesper Juhl
On Wed, 11 Apr 2012, Greg Kroah-Hartman wrote: > On Thu, Apr 12, 2012 at 01:17:52AM +0200, Jesper Juhl wrote: > > On Wed, 11 Apr 2012, Greg Kroah-Hartman wrote: > > > > > On Wed, Apr 11, 2012 at 06:46:33PM -0400, Xi Wang wrote: > > > > On Apr 11,

Re: [PATCH] staging: vt6656: Don't leak memory in drivers/staging/vt6656/ioctl.c::private_ioctl()

2012-04-11 Thread Jesper Juhl
On Wed, 11 Apr 2012, Greg Kroah-Hartman wrote: > On Wed, Apr 11, 2012 at 06:46:33PM -0400, Xi Wang wrote: > > On Apr 11, 2012, at 6:35 PM, Jesper Juhl wrote: > > > > > - pNodeList = (PSNodeList)kmalloc(sizeof(SNodeList) + > > > (sNodeList.uItem * si

[PATCH] staging: vt6656: Don't leak memory in drivers/staging/vt6656/ioctl.c::private_ioctl()

2012-04-11 Thread Jesper Juhl
PSNodeList') of a kmalloc() return value - kmalloc() returns a void pointer that is implicitly converted, so there is no need for an explicit cast. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/ioctl.c |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/st

Re: [PATCH] staging: android: fix mem leaks in __persistent_ram_init()

2012-04-11 Thread Jesper Juhl
On Wed, 11 Apr 2012, Colin Cross wrote: > On Wed, Apr 11, 2012 at 1:10 PM, Jesper Juhl wrote: > > If, in __persistent_ram_init(), the call to > > persistent_ram_buffer_init() fails or the call to > > persistent_ram_init_ecc() fails then we fail to free the memory we > &

[PATCH] staging: android: fix mem leaks in __persistent_ram_init()

2012-04-11 Thread Jesper Juhl
ee(NULL) call in the case of kzalloc() itself failing that's OK since kfree() deals gracefully with NULL pointers and I felt it was more important to keep all error exits at a single location than to avoid that one harmless/redundant kfree() on a error path. Signed-off-by: Jesper Juhl --

[PATCH 21/26] staging: vt6656: Don't needlessly test for NULL before release_firmware()

2012-04-09 Thread Jesper Juhl
Checking for a NULL pointer before calling release_firmware() is redundant since the function does that check itself. Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/main_usb.c |4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/staging/vt6656/main_usb.c b

[PATCH 20/26] [media] staging: as102: Remove redundant NULL check before release_firmware() and pointless comments

2012-04-09 Thread Jesper Juhl
st stating that add no value. Signed-off-by: Jesper Juhl --- drivers/staging/media/as102/as102_fw.c |5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/staging/media/as102/as102_fw.c b/drivers/staging/media/as102/as102_fw.c index 43ebc43..9db275e 100644 --- a/driver

[PATCH] staging/media/as102: Don't call release_firmware() on uninitialized variable

2012-03-24 Thread Jesper Juhl
are' still uninitialized - not good. The easy fix is to just initialize 'firmware' to NULL when we declare it, since release_firmware() deals gracefully with being passed NULL pointers. Signed-off-by: Jesper Juhl --- drivers/staging/media/as102/as102_fw.c |2 +- 1 file changed,

[PATCH] Staging, rtl8192e, softmac: remove redundant memset and fix mem leak

2012-02-12 Thread Jesper Juhl
e where we take the branch and when we don't. Signed-off-by: Jesper Juhl --- drivers/staging/rtl8192e/rtllib_softmac.c |3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) Compile tested only. diff --git a/drivers/staging/rtl8192e/rtllib_softmac.c b/drivers/staging/rtl8192e/rtllib_so

Re: Staging: bcm: Don't leak 'pstAddIndication' in CmHost.c::StoreCmControlResponseMessage()

2012-02-11 Thread Jesper Juhl
On Fri, 10 Feb 2012, Greg KH wrote: > On Thu, Feb 09, 2012 at 11:33:25PM +0100, Jesper Juhl wrote: > > From: Jesper Juhl > > > > We allocate memory for 'pstAddIndication' with kmalloc() in > > drivers/staging/bcm/CmHost.c::StoreCmControlResponseMessage()

Re: [PATCH 2/2] Staging; Don't leak 'pstAddIndication' in CmHost.c::StoreCmControlResponseMessage()

2012-02-09 Thread Jesper Juhl
On Thu, 9 Feb 2012, Greg KH wrote: > On Tue, Jan 24, 2012 at 11:47:27PM +0100, Jesper Juhl wrote: > > We allocate memory for 'pstAddIndication' with kmalloc() in > > drivers/staging/bcm/CmHost.c::StoreCmControlResponseMessage() and then > > neglect to free it on a

[PATCH] Staging: Don't double-include linux/module.h in drivers/staging/iio/gyro/adis16060_core.c

2012-02-04 Thread Jesper Juhl
Signed-off-by: Jesper Juhl --- drivers/staging/iio/gyro/adis16060_core.c |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/drivers/staging/iio/gyro/adis16060_core.c b/drivers/staging/iio/gyro/adis16060_core.c index c0ca709..02cc234 100644 --- a/drivers/staging/iio/gyro

[PATCH] Staging: The header linux/module.h is included twice in drivers/staging/iio/dac/ad5686.c

2012-02-04 Thread Jesper Juhl
Remove the unneeded duplicate. Signed-off-by: Jesper Juhl --- drivers/staging/iio/dac/ad5686.c |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/drivers/staging/iio/dac/ad5686.c b/drivers/staging/iio/dac/ad5686.c index ce2d619..2415a6e 100644 --- a/drivers/staging/iio/dac

Re: [PATCH 1/1] staging: rts5139: Fixed coding style issues

2012-01-30 Thread Jesper Juhl
On Mon, 30 Jan 2012, Autif Khan wrote: > > Signed-off-by: Autif Khan Yeah, looks OK. Reviewed-by: Jesper Juhl > --- > drivers/staging/rts5139/ms.h |4 ++-- > drivers/staging/rts5139/rts51x_chip.h |6 +++--- > drivers/staging/rts5139/rts51x_

[PATCH] staging, media, easycap: Fix mem leak in easycap_usb_probe()

2012-01-29 Thread Jesper Juhl
b_free_urb() before the return. Signed-off-by: Jesper Juhl --- drivers/staging/media/easycap/easycap_main.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) compile tested only diff --git a/drivers/staging/media/easycap/easycap_main.c b/drivers/staging/media/easycap/easycap_main.c

Re: [PATCH 1/2] Staging; bcm/CmHost.c: Style cleanup

2012-01-27 Thread Jesper Juhl
On Wed, 25 Jan 2012, Dan Carpenter wrote: > This is probably going to need to be redone on top of the other bcm > cleanup patches anyway. > If that turns out to be so, well, so be it. I was not aware of other patches, so my bad... > On Tue, Jan 24, 2012 at 11:46:31PM +0100, Jespe

Re: [PATCH 1/2] Staging; bcm/CmHost.c: Style cleanup

2012-01-24 Thread Jesper Juhl
On Tue, 24 Jan 2012, Joe Perches wrote: > On Tue, 2012-01-24 at 23:46 +0100, Jesper Juhl wrote: > > This patch tries to bring drivers/staging/bcm/CmHost.c somewhat in > > line with CodingStyle. > > There are already a couple of CmHost patches waiting. > Thank you for th

[PATCH 2/2] Staging; Don't leak 'pstAddIndication' in CmHost.c::StoreCmControlResponseMessage()

2012-01-24 Thread Jesper Juhl
y case, so I opted for just fixing the problem as directly as I could and then we can clean it up generally later... This at least makes it stop bleeding.. Signed-off-by: Jesper Juhl --- drivers/staging/bcm/CmHost.c | 27 --- 1 files changed, 20 insertions(+), 7 deletion

[PATCH 0/2] Staging: Style cleanup and mem leak fixes for drivers/staging/bcm/CmHost.c

2012-01-24 Thread Jesper Juhl
nd thought "Ok, before I touch anything in here I'm going to clean it up to at least not hurt my eyes anymore". So, the result is these two patches; the first does a basic style cleanup - far from perfect, but a huge improvement on what was there before, and the second fixes a few

[PATCH 2/2] staging, vt6656/wpactl.c: Fix mem leak in wpa_ioctl()

2012-01-16 Thread Jesper Juhl
If we hit the default case in the switch statement in wpa_ioctl() we'll leak the memory allocated to 'param' when the variable goes out of scope without having been assigned to anything. This patch fixes the leak by kfree()'ing the memory before we return from the function. S

[PATCH 1/2] staging, vt6656/wpactl.c: A basic style cleanup

2012-01-16 Thread Jesper Juhl
it's ever needed in the future). Signed-off-by: Jesper Juhl --- drivers/staging/vt6656/wpactl.c | 936 +-- 1 files changed, 418 insertions(+), 518 deletions(-) diff --git a/drivers/staging/vt6656/wpactl.c b/drivers/staging/vt6656/wpactl.c index 2fa4f84.

Re: [PATCH] [staging] iio, adc: Do not leak memory in ad7280_event_handler()

2011-12-05 Thread Jesper Juhl
On Sat, 26 Nov 2011, Greg KH wrote: > On Sun, Nov 06, 2011 at 10:49:22PM +0100, Jesper Juhl wrote: > > If ad7280_read_all_channels() returns <0 then we'll leak the memory > > allocated to 'channels' when we return and that variable goes out of > > scope. &

Re: [PATCH] staging: rtl8192e: Use kzalloc rather than kmalloc

2011-11-08 Thread Jesper Juhl
On Tue, 8 Nov 2011, Thomas Meyer wrote: > From: Thomas Meyer > You should seriously consider giving your patch mails unique subjects. Many patches with identical subjects are prone to be missed by people on the list and it's also harder to refer to a specific patch later. --

[PATCH] rtl8192e: Don't copy huge struct by value (and make it const).

2011-11-06 Thread Jesper Juhl
Signed-off-by: Jesper Juhl --- drivers/staging/rtl8192e/rtllib.h |2 +- drivers/staging/rtl8192e/rtllib_softmac.c |4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/staging/rtl8192e/rtllib.h b/drivers/staging/rtl8192e/rtllib.h index de25975..3a521

[PATCH] [staging] iio, adc: Do not leak memory in ad7280_event_handler()

2011-11-06 Thread Jesper Juhl
If ad7280_read_all_channels() returns <0 then we'll leak the memory allocated to 'channels' when we return and that variable goes out of scope. This patch fixes the leak. Signed-off-by: Jesper Juhl --- drivers/staging/iio/adc/ad7280a.c |4 +++- 1 files changed, 3 insertio

  1   2   >