All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] staging: rtl8192e: remove condition with no effect
@ 2021-10-27 18:34 Saurav Girepunje
  2021-10-30  9:15 ` Greg KH
  0 siblings, 1 reply; 3+ messages in thread
From: Saurav Girepunje @ 2021-10-27 18:34 UTC (permalink / raw)
  To: gregkh, dan.carpenter, will+git, mitaliborkar810,
	eduard.vintila47, saurav.girepunje, zhaoxiao, linux-staging,
	linux-kernel
  Cc: saurav.girepunje

Remove the if and else code section for variable pHTInfo->bRegBW40MHz.
Just before the if condition variable is assign with value 1.
So if condition check for pHTInfo->bRegBW40MHz is always true.

Similarly for the variable pHTInfo->SelfMimoPs value '3' is assign.
So if condition check with value '2' will never be true. Remove the
if condition check for pHTInfo->SelfMimoPs.

Remove the extra blank lines from HTUpdateDefaultSetting function.

Signed-off-by: Saurav Girepunje <saurav.girepunje@gmail.com>
---
 drivers/staging/rtl8192e/rtl819x_HTProc.c | 16 +---------------
 1 file changed, 1 insertion(+), 15 deletions(-)

diff --git a/drivers/staging/rtl8192e/rtl819x_HTProc.c b/drivers/staging/rtl8192e/rtl819x_HTProc.c
index 3b8efaf9b88c..6925654dbc03 100644
--- a/drivers/staging/rtl8192e/rtl819x_HTProc.c
+++ b/drivers/staging/rtl8192e/rtl819x_HTProc.c
@@ -72,34 +72,20 @@ void HTUpdateDefaultSetting(struct rtllib_device *ieee)
 	struct rt_hi_throughput *pHTInfo = ieee->pHTInfo;

 	pHTInfo->bAcceptAddbaReq = 1;
-
 	pHTInfo->bRegShortGI20MHz = 1;
 	pHTInfo->bRegShortGI40MHz = 1;
-
 	pHTInfo->bRegBW40MHz = 1;
-
-	if (pHTInfo->bRegBW40MHz)
-		pHTInfo->bRegSuppCCK = 1;
-	else
-		pHTInfo->bRegSuppCCK = true;
-
+	pHTInfo->bRegSuppCCK = 1;
 	pHTInfo->nAMSDU_MaxSize = 7935UL;
 	pHTInfo->bAMSDU_Support = 0;
-
 	pHTInfo->bAMPDUEnable = 1;
 	pHTInfo->AMPDU_Factor = 2;
 	pHTInfo->MPDU_Density = 0;
-
 	pHTInfo->SelfMimoPs = 3;
-	if (pHTInfo->SelfMimoPs == 2)
-		pHTInfo->SelfMimoPs = 3;
 	ieee->bTxDisableRateFallBack = 0;
 	ieee->bTxUseDriverAssingedRate = 0;
-
 	ieee->bTxEnableFwCalcDur = 1;
-
 	pHTInfo->bRegRT2RTAggregation = 1;
-
 	pHTInfo->bRegRxReorderEnable = 1;
 	pHTInfo->RxReorderWinSize = 64;
 	pHTInfo->RxReorderPendingTime = 30;
--
2.33.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] staging: rtl8192e: remove condition with no effect
  2021-10-27 18:34 [PATCH] staging: rtl8192e: remove condition with no effect Saurav Girepunje
@ 2021-10-30  9:15 ` Greg KH
  2021-10-31 18:58   ` Saurav Girepunje
  0 siblings, 1 reply; 3+ messages in thread
From: Greg KH @ 2021-10-30  9:15 UTC (permalink / raw)
  To: Saurav Girepunje
  Cc: dan.carpenter, will+git, mitaliborkar810, eduard.vintila47,
	zhaoxiao, linux-staging, linux-kernel, saurav.girepunje

On Thu, Oct 28, 2021 at 12:04:43AM +0530, Saurav Girepunje wrote:
> Remove the if and else code section for variable pHTInfo->bRegBW40MHz.
> Just before the if condition variable is assign with value 1.
> So if condition check for pHTInfo->bRegBW40MHz is always true.
> 
> Similarly for the variable pHTInfo->SelfMimoPs value '3' is assign.
> So if condition check with value '2' will never be true. Remove the
> if condition check for pHTInfo->SelfMimoPs.
> 
> Remove the extra blank lines from HTUpdateDefaultSetting function.
> 
> Signed-off-by: Saurav Girepunje <saurav.girepunje@gmail.com>
> ---
>  drivers/staging/rtl8192e/rtl819x_HTProc.c | 16 +---------------
>  1 file changed, 1 insertion(+), 15 deletions(-)
> 
> diff --git a/drivers/staging/rtl8192e/rtl819x_HTProc.c b/drivers/staging/rtl8192e/rtl819x_HTProc.c
> index 3b8efaf9b88c..6925654dbc03 100644
> --- a/drivers/staging/rtl8192e/rtl819x_HTProc.c
> +++ b/drivers/staging/rtl8192e/rtl819x_HTProc.c
> @@ -72,34 +72,20 @@ void HTUpdateDefaultSetting(struct rtllib_device *ieee)
>  	struct rt_hi_throughput *pHTInfo = ieee->pHTInfo;
> 
>  	pHTInfo->bAcceptAddbaReq = 1;
> -
>  	pHTInfo->bRegShortGI20MHz = 1;
>  	pHTInfo->bRegShortGI40MHz = 1;
> -
>  	pHTInfo->bRegBW40MHz = 1;
> -
> -	if (pHTInfo->bRegBW40MHz)
> -		pHTInfo->bRegSuppCCK = 1;
> -	else
> -		pHTInfo->bRegSuppCCK = true;
> -
> +	pHTInfo->bRegSuppCCK = 1;
>  	pHTInfo->nAMSDU_MaxSize = 7935UL;
>  	pHTInfo->bAMSDU_Support = 0;
> -
>  	pHTInfo->bAMPDUEnable = 1;
>  	pHTInfo->AMPDU_Factor = 2;
>  	pHTInfo->MPDU_Density = 0;
> -
>  	pHTInfo->SelfMimoPs = 3;
> -	if (pHTInfo->SelfMimoPs == 2)
> -		pHTInfo->SelfMimoPs = 3;
>  	ieee->bTxDisableRateFallBack = 0;
>  	ieee->bTxUseDriverAssingedRate = 0;
> -
>  	ieee->bTxEnableFwCalcDur = 1;
> -
>  	pHTInfo->bRegRT2RTAggregation = 1;
> -
>  	pHTInfo->bRegRxReorderEnable = 1;
>  	pHTInfo->RxReorderWinSize = 64;
>  	pHTInfo->RxReorderPendingTime = 30;
> --
> 2.33.0
> 
> 

Hi,

This is the friendly patch-bot of Greg Kroah-Hartman.  You have sent him
a patch that has triggered this response.  He used to manually respond
to these common problems, but in order to save his sanity (he kept
writing the same thing over and over, yet to different people), I was
created.  Hopefully you will not take offence and will fix the problem
in your patch and resubmit it so that it can be accepted into the Linux
kernel tree.

You are receiving this message because of the following common error(s)
as indicated below:

- Your patch did many different things all at once, making it difficult
  to review.  All Linux kernel patches need to only do one thing at a
  time.  If you need to do multiple things (such as clean up all coding
  style issues in a file/driver), do it in a sequence of patches, each
  one doing only one thing.  This will make it easier to review the
  patches to ensure that they are correct, and to help alleviate any
  merge issues that larger patches can cause.

If you wish to discuss this problem further, or you have questions about
how to resolve this issue, please feel free to respond to this email and
Greg will reply once he has dug out from the pending patches received
from other developers.

thanks,

greg k-h's patch email bot

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] staging: rtl8192e: remove condition with no effect
  2021-10-30  9:15 ` Greg KH
@ 2021-10-31 18:58   ` Saurav Girepunje
  0 siblings, 0 replies; 3+ messages in thread
From: Saurav Girepunje @ 2021-10-31 18:58 UTC (permalink / raw)
  To: Greg KH
  Cc: dan.carpenter, will+git, mitaliborkar810, eduard.vintila47,
	zhaoxiao, linux-staging, linux-kernel, saurav.girepunje,
	Pavel Skripkin



On 30/10/21 2:45 pm, Greg KH wrote:
> On Thu, Oct 28, 2021 at 12:04:43AM +0530, Saurav Girepunje wrote:
>> Remove the if and else code section for variable pHTInfo->bRegBW40MHz.
>> Just before the if condition variable is assign with value 1.
>> So if condition check for pHTInfo->bRegBW40MHz is always true.
>>
>> Similarly for the variable pHTInfo->SelfMimoPs value '3' is assign.
>> So if condition check with value '2' will never be true. Remove the
>> if condition check for pHTInfo->SelfMimoPs.
>>
>> Remove the extra blank lines from HTUpdateDefaultSetting function.
>>
>> Signed-off-by: Saurav Girepunje <saurav.girepunje@gmail.com>
>> ---
>>  drivers/staging/rtl8192e/rtl819x_HTProc.c | 16 +---------------
>>  1 file changed, 1 insertion(+), 15 deletions(-)
>>
>> diff --git a/drivers/staging/rtl8192e/rtl819x_HTProc.c b/drivers/staging/rtl8192e/rtl819x_HTProc.c
>> index 3b8efaf9b88c..6925654dbc03 100644
>> --- a/drivers/staging/rtl8192e/rtl819x_HTProc.c
>> +++ b/drivers/staging/rtl8192e/rtl819x_HTProc.c
>> @@ -72,34 +72,20 @@ void HTUpdateDefaultSetting(struct rtllib_device *ieee)
>>  	struct rt_hi_throughput *pHTInfo = ieee->pHTInfo;
>>
>>  	pHTInfo->bAcceptAddbaReq = 1;
>> -
>>  	pHTInfo->bRegShortGI20MHz = 1;
>>  	pHTInfo->bRegShortGI40MHz = 1;
>> -
>>  	pHTInfo->bRegBW40MHz = 1;
>> -
>> -	if (pHTInfo->bRegBW40MHz)
>> -		pHTInfo->bRegSuppCCK = 1;
>> -	else
>> -		pHTInfo->bRegSuppCCK = true;
>> -
>> +	pHTInfo->bRegSuppCCK = 1;
>>  	pHTInfo->nAMSDU_MaxSize = 7935UL;
>>  	pHTInfo->bAMSDU_Support = 0;
>> -
>>  	pHTInfo->bAMPDUEnable = 1;
>>  	pHTInfo->AMPDU_Factor = 2;
>>  	pHTInfo->MPDU_Density = 0;
>> -
>>  	pHTInfo->SelfMimoPs = 3;
>> -	if (pHTInfo->SelfMimoPs == 2)
>> -		pHTInfo->SelfMimoPs = 3;
>>  	ieee->bTxDisableRateFallBack = 0;
>>  	ieee->bTxUseDriverAssingedRate = 0;
>> -
>>  	ieee->bTxEnableFwCalcDur = 1;
>> -
>>  	pHTInfo->bRegRT2RTAggregation = 1;
>> -
>>  	pHTInfo->bRegRxReorderEnable = 1;
>>  	pHTInfo->RxReorderWinSize = 64;
>>  	pHTInfo->RxReorderPendingTime = 30;
>> --
>> 2.33.0
>>
>>
> 
> Hi,
> 
> This is the friendly patch-bot of Greg Kroah-Hartman.  You have sent him
> a patch that has triggered this response.  He used to manually respond
> to these common problems, but in order to save his sanity (he kept
> writing the same thing over and over, yet to different people), I was
> created.  Hopefully you will not take offence and will fix the problem
> in your patch and resubmit it so that it can be accepted into the Linux
> kernel tree.
> 
> You are receiving this message because of the following common error(s)
> as indicated below:
> 
> - Your patch did many different things all at once, making it difficult
>   to review.  All Linux kernel patches need to only do one thing at a
>   time.  If you need to do multiple things (such as clean up all coding
>   style issues in a file/driver), do it in a sequence of patches, each
>   one doing only one thing.  This will make it easier to review the
>   patches to ensure that they are correct, and to help alleviate any
>   merge issues that larger patches can cause.

> If you wish to discuss this problem further, or you have questions about
> how to resolve this issue, please feel free to respond to this email and
> Greg will reply once he has dug out from the pending patches received
> from other developers.
> 
> thanks,
> 
> greg k-h's patch email bot
> 

I will break this in multiple patch , One thing at a time.

Regards,
Saurav 

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-10-31 18:58 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-27 18:34 [PATCH] staging: rtl8192e: remove condition with no effect Saurav Girepunje
2021-10-30  9:15 ` Greg KH
2021-10-31 18:58   ` Saurav Girepunje

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.