[PATCH] staging:iio:impedance-analyzer:ad5933: Macro replacment Cleanups.

2018-06-24 Thread Karim Eshapa
Doing some macro replacment to start an array of structures so it can be reused by manipulating it with different values. Signed-off-by: Karim Eshapa --- .../staging/iio/impedance-analyzer/ad5933.c | 57 +++ 1 file changed, 19 insertions(+), 38 deletions(-) diff --git

Re: [PATCH v2 3/8] staging: rtl8192u: User memset to initialize memory, instead of loop.

2018-06-24 Thread Joe Perches
On Sun, 2018-06-24 at 10:57 +0100, John Whitmore wrote: > Replaced memory initialising loop with memset, as suggested by Andy Shevchenko [] > diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c > b/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c [] > @@ -742,8 +742,6 @@ void

[PATCH v3] staging: pi433: replace simple switch statements

2018-06-24 Thread Valentin Vidic
Use const array to map switch cases to resulting values. Signed-off-by: Valentin Vidic --- v2: use correct type for const arrays v3: add missing static keyword for af_map drivers/staging/pi433/rf69.c | 233 ++- 1 file changed, 93 insertions(+), 140 deletions(-)

[PATCH v2] staging: pi433: replace simple switch statements

2018-06-24 Thread Valentin Vidic
Use const array to map switch cases to resulting values. Signed-off-by: Valentin Vidic --- v2: use correct type for const arrays drivers/staging/pi433/rf69.c | 233 ++- 1 file changed, 93 insertions(+), 140 deletions(-) diff --git a/drivers/staging/pi433/rf69.c

Re: [PATCH] staging: pi433: replace simple switch statements

2018-06-24 Thread Joe Perches
On Sun, 2018-06-24 at 11:42 +0200, Valentin Vidic wrote: > Use const array to map switch cases to resulting values. I suggest you make the const arrays the same type as the argument in the function being called. > diff --git a/drivers/staging/pi433/rf69.c b/drivers/staging/pi433/rf69.c [] > @@

Re: [PATCH v3 7/8] staging: rtl8192u: Correct if statement - Coding Style

2018-06-24 Thread Joe Perches
On Sun, 2018-06-24 at 16:34 +0100, John Whitmore wrote: > Corrected the coding style of if statement. [] > diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c > b/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c [] > @@ -732,7 +732,7 @@ void HTConstructRT2RTAggElement(struct

Re: [PATCH v3 3/8] staging: rtl8192u: User memset to initialize memory, instead of loop.

2018-06-24 Thread John Whitmore
Sorry having difficulty getting the full v3 patch set sent using git send-email. Only one seems to be going out. Sorry about the noise. ___ devel mailing list de...@linuxdriverproject.org

[PATCH v3 7/8] staging: rtl8192u: Correct if statement - Coding Style

2018-06-24 Thread John Whitmore
Corrected the coding style of if statement. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

[PATCH v3 5/8] staging: rtl8192u: Use %s and __func__ instead of hardcoded string - Style

2018-06-24 Thread John Whitmore
Changed a number of hard coded function names to use %s and __func__ Mailing list response suggest that there is a better method for debugging using netdev_dbg(). I can't argue with that, but for the moment this change will clear the checkpatch.pl Warning. Signed-off-by: John Whitmore ---

[PATCH v3 6/8] staging: rtl8192u: Remove braces from single statement blocks - Style

2018-06-24 Thread John Whitmore
Removed the unrequired braces from single statement blocks - Coding Style. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

[PATCH v3 8/8] staging: rtl8192u: Correction of spelling mistake in comment.

2018-06-24 Thread John Whitmore
Simple spelling correction. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c b/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c index

[PATCH v3 3/8] staging: rtl8192u: User memset to initialize memory, instead of loop.

2018-06-24 Thread John Whitmore
Replaced memory initialising loop with memset, as suggested by Andy Shevchenko Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

[PATCH v3 4/8] staging: rtl8192u: Truncate block comments to 80 character length - Style

2018-06-24 Thread John Whitmore
Where possible truncation of block comments to the 80 character length preferred by the coding style. In a previous version of this commit some of the comments were contentious so those have not been touched in this version. Signed-off-by: John Whitmore ---

staging: rtl8192u: V3 Coding style changes. Plus one change to use memset()

2018-06-24 Thread John Whitmore
Simple coding style changes to single file drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c Given feedback on some of the comments, I truncated to the 80 character limit, in code, (as opposed to function block comments). I have left a number of the contentious comments as they are. Another

[PATCH v3 1/8] staging: rtl8192u: change block comments to prefered style - Coding Style

2018-06-24 Thread John Whitmore
Some of the comment blocks are commening out code so have been left for the moment. Signed-off-by: John Whitmore --- .../rtl8192u/ieee80211/rtl819x_HTProc.c | 366 ++ 1 file changed, 195 insertions(+), 171 deletions(-) diff --git

[PATCH v3 2/8] staging: rtl8192u: Correct indentation of switch statement - Coding Style

2018-06-24 Thread John Whitmore
Removed an extra indentation from the code of the various case options in a switch statement. Signed-off-by: John Whitmore --- .../rtl8192u/ieee80211/rtl819x_HTProc.c | 30 +-- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git

[PATCH v3 1/8] staging: rtl8192u: change block comments to prefered style - Coding Style

2018-06-24 Thread John Whitmore
Some of the comment blocks are commening out code so have been left for the moment. Signed-off-by: John Whitmore --- .../rtl8192u/ieee80211/rtl819x_HTProc.c | 366 ++ 1 file changed, 195 insertions(+), 171 deletions(-) diff --git

[PATCH v3 5/8] staging: rtl8192u: Use %s and __func__ instead of hardcoded string - Style

2018-06-24 Thread John Whitmore
Changed a number of hard coded function names to use %s and __func__ Mailing list response suggest that there is a better method for debugging using netdev_dbg(). I can't argue with that, but for the moment this change will clear the checkpatch.pl Warning. Signed-off-by: John Whitmore ---

[PATCH v3 2/8] staging: rtl8192u: Correct indentation of switch statement - Coding Style

2018-06-24 Thread John Whitmore
Removed an extra indentation from the code of the various case options in a switch statement. Signed-off-by: John Whitmore --- .../rtl8192u/ieee80211/rtl819x_HTProc.c | 30 +-- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git

[PATCH v3 7/8] staging: rtl8192u: Correct if statement - Coding Style

2018-06-24 Thread John Whitmore
Corrected the coding style of if statement. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

[PATCH v3 4/8] staging: rtl8192u: Truncate block comments to 80 character length - Style

2018-06-24 Thread John Whitmore
Where possible truncation of block comments to the 80 character length preferred by the coding style. In a previous version of this commit some of the comments were contentious so those have not been touched in this version. Signed-off-by: John Whitmore ---

[PATCH v3 6/8] staging: rtl8192u: Remove braces from single statement blocks - Style

2018-06-24 Thread John Whitmore
Removed the unrequired braces from single statement blocks - Coding Style. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

[PATCH v3 8/8] staging: rtl8192u: Correction of spelling mistake in comment.

2018-06-24 Thread John Whitmore
Simple spelling correction. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c b/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c index

staging: rtl8192u: v3 Coding style changes. Plus one change to use memset()

2018-06-24 Thread John Whitmore
Simple coding style changes to single file drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c Given feedback on some of the comments, I truncated to the 80 character limit, in code, (as opposed to function block comments). I have left a number of the contentious comments as they are. Another

[PATCH v3 3/8] staging: rtl8192u: User memset to initialize memory, instead of loop.

2018-06-24 Thread John Whitmore
Replaced memory initialising loop with memset, as suggested by Andy Shevchenko Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

Re: [PATCH v2 3/8] staging: rtl8192u: User memset to initialize memory, instead of loop.

2018-06-24 Thread John Whitmore
On Sun, Jun 24, 2018 at 07:26:41AM -0700, Joe Perches wrote: > On Sun, 2018-06-24 at 10:57 +0100, John Whitmore wrote: > > Replaced memory initialising loop with memset, as suggested by Andy > > Shevchenko > [] > > diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c > >

Re: [PATCH v2 3/8] staging: rtl8192u: User memset to initialize memory, instead of loop.

2018-06-24 Thread John Whitmore
On Sun, Jun 24, 2018 at 07:26:41AM -0700, Joe Perches wrote: > On Sun, 2018-06-24 at 10:57 +0100, John Whitmore wrote: > > Replaced memory initialising loop with memset, as suggested by Andy > > Shevchenko > [] > > diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c > >

Re: [PATCH v3] staging:iio:accel:adis16240: sign extend function replace hard code duplication

2018-06-24 Thread Jonathan Cameron
On Mon, 18 Jun 2018 19:44:50 +0200 Karim Eshapa wrote: > Use sign_extend32 kernel function instead of code duplication, > Safe also for 16 bit. and remove declaration of bits variable not needed. > > Signed-off-by: Karim Eshapa Applied, thanks. Jonathan > --- >

Re: V2 Coding style changes. Plus one change to use memset()

2018-06-24 Thread John Whitmore
On Sun, Jun 24, 2018 at 06:53:24PM +0800, Greg KH wrote: > On Sun, Jun 24, 2018 at 10:57:24AM +0100, John Whitmore wrote: > > Simple coding style changes to single file > > drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c > > Nit, please include the driver and subsystem in your 00/XX emails, >

Re: V2 Coding style changes. Plus one change to use memset()

2018-06-24 Thread Greg KH
On Sun, Jun 24, 2018 at 10:57:24AM +0100, John Whitmore wrote: > Simple coding style changes to single file > drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c Nit, please include the driver and subsystem in your 00/XX emails, otherwise they get lost in my filters and I see an odd

[PATCH v2 8/8] staging: rtl8192u: Correction of spelling mistake in comment.

2018-06-24 Thread John Whitmore
Simple spelling correction. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c b/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c index

[PATCH v2 7/8] staging: rtl8192u: Correct if statement - Coding Style

2018-06-24 Thread John Whitmore
Corrected the coding style of if statement. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

[PATCH v2 4/8] staging: rtl8192u: Truncate block comments to 80 character length - Style

2018-06-24 Thread John Whitmore
Where possible truncation of block comments to the 80 character length preferred by the coding style. In a previous version of this commit some of the comments were contentious so those have not been touched in this version. Signed-off-by: John Whitmore ---

[PATCH v2 2/8] staging: rtl8192u: Correct indentation of switch statement - Coding Style

2018-06-24 Thread John Whitmore
Removed an extra indentation from the code of the various case options in a switch statement. Signed-off-by: John Whitmore --- .../rtl8192u/ieee80211/rtl819x_HTProc.c | 30 +-- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git

[PATCH v2 6/8] staging: rtl8192u: Remove braces from single statement blocks - Style

2018-06-24 Thread John Whitmore
Removed the unrequired braces from single statement blocks - Coding Style. Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

[PATCH v2 1/8] staging: rtl8192u: change block comments to prefered style - Coding Style

2018-06-24 Thread John Whitmore
Some of the comment blocks are commening out code so have been left for the moment. Signed-off-by: John Whitmore --- .../rtl8192u/ieee80211/rtl819x_HTProc.c | 366 ++ 1 file changed, 195 insertions(+), 171 deletions(-) diff --git

V2 Coding style changes. Plus one change to use memset()

2018-06-24 Thread John Whitmore
Simple coding style changes to single file drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c Given feedback on some of the comments, I truncated to the 80 character limit, in code, (as opposed to function block comments). I have left a number of the contentious comments as they are. Another

[PATCH v2 3/8] staging: rtl8192u: User memset to initialize memory, instead of loop.

2018-06-24 Thread John Whitmore
Replaced memory initialising loop with memset, as suggested by Andy Shevchenko Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

[PATCH v2 5/8] staging: rtl8192u: Use %s and __func__ instead of hardcoded string - Style

2018-06-24 Thread John Whitmore
Changed a number of hard coded function names to use %s and __func__ Mailing list response suggest that there is a better method for debugging using netdev_dbg(). I can't argue with that, but for the moment this change will clear the checkpatch.pl Warning. Signed-off-by: John Whitmore ---

[PATCH] staging: pi433: replace simple switch statements

2018-06-24 Thread Valentin Vidic
Use const array to map switch cases to resulting values. Signed-off-by: Valentin Vidic --- drivers/staging/pi433/rf69.c | 233 ++- 1 file changed, 93 insertions(+), 140 deletions(-) diff --git a/drivers/staging/pi433/rf69.c b/drivers/staging/pi433/rf69.c index