lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <c09a450d-7b5a-b0fa-c435-b5778de8b05a@gmail.com>
Date:   Fri, 13 Nov 2020 09:56:01 -0500
From:   Jes Sorensen <jes.sorensen@...il.com>
To:     xiakaixu1987@...il.com, kvalo@...eaurora.org, chiu@...lessm.com
Cc:     linux-wireless@...r.kernel.org, linux-kernel@...r.kernel.org,
        Kaixu Xia <kaixuxia@...cent.com>
Subject: Re: [PATCH] rtl8xxxu: remove the unused variable timeout value
 assignment

On 11/13/20 4:50 AM, xiakaixu1987@...il.com wrote:
> From: Kaixu Xia <kaixuxia@...cent.com>
> 
> The value of variable timeout is overwritten by the following statement in
> rtl8xxxu_gen1_init_aggregation(), so here the value assignment is useless.
> Remove it.
> 
> Reported-by: Tosk Robot <tencent_os_robot@...cent.com>
> Signed-off-by: Kaixu Xia <kaixuxia@...cent.com>
> ---
>  drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c
> index 5cd7ef3..342126b 100644
> --- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c
> +++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c
> @@ -4426,7 +4426,7 @@ void rtl8xxxu_gen1_init_aggregation(struct rtl8xxxu_priv *priv)
>  	page_thresh = (priv->fops->rx_agg_buf_size / 512);
>  	if (rtl8xxxu_dma_agg_pages >= 0) {
>  		if (rtl8xxxu_dma_agg_pages <= page_thresh)
> -			timeout = page_thresh;
> +			; /* do nothing */

Sorry this is the wrong way to do this. If the if statement is no longer
needed, then remove it, don't just make it do nothing.

Nack

Jes

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ