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]
Date:   Wed, 9 Feb 2022 23:33:22 +0300
From:   Pavel Skripkin <paskripkin@...il.com>
To:     Leonardo Araujo <leonardo.aa88@...il.com>,
        gregkh@...uxfoundation.org
Cc:     linux-kernel@...r.kernel.org, linux-staging@...ts.linux.dev
Subject: Re: [PATCH] Staging: r8188eu: core: Comparisons should place the
 constant on the right side of the test

Hi Leonardo,

On 2/9/22 23:27, Leonardo Araujo wrote:
> This patch fixes the following checkpatch.pl warning:
> 
> WARNING: Comparisons should place the constant on the right side of the test
> 
> Signed-off-by: Leonardo Araujo <leonardo.aa88@...il.com>
> ---
>   drivers/staging/r8188eu/core/rtw_cmd.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/r8188eu/core/rtw_cmd.c b/drivers/staging/r8188eu/core/rtw_cmd.c
> index a9a5453aa1cc..e236316188c1 100644
> --- a/drivers/staging/r8188eu/core/rtw_cmd.c
> +++ b/drivers/staging/r8188eu/core/rtw_cmd.c
> @@ -618,7 +618,7 @@ u8 rtw_disassoc_cmd(struct adapter *padapter, u32 deauth_timeout_ms, bool enqueu
>   		res = rtw_enqueue_cmd(cmdpriv, cmdobj);
>   	} else {
>   		/* no need to enqueue, do the cmd hdl directly and free cmd parameter */
> -		if (H2C_SUCCESS != disconnect_hdl(padapter, (u8 *)param))
> +		if (disconnect_hdl(padapter, (u8 *)param) != H2C_SUCCESS)

Actually disconnect_hdl() always return H2C_SUCCESS. Looks like this 
check can be dropped completely

Unfortunately, we can't make it return void, since it's used as part of 
wlancmds array :(



With regards,
Pavel Skripkin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ