Re: [PATCH] scsi: qla2xxx: Simplify the calculation of variables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> On Feb 2, 2021, at 8:26 PM, Jiapeng Chong <jiapeng.chong@xxxxxxxxxxxxxxxxx> wrote:
> 
> Fix the following coccicheck warnings:
> 
> ./drivers/scsi/qla2xxx/qla_target.c:984:12-14: WARNING !A || A && B is
> equivalent to !A || B.
> 
> Reported-by: Abaci Robot <abaci@xxxxxxxxxxxxxxxxx>
> Signed-off-by: Jiapeng Chong <jiapeng.chong@xxxxxxxxxxxxxxxxx>
> ---
> drivers/scsi/qla2xxx/qla_target.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/scsi/qla2xxx/qla_target.c b/drivers/scsi/qla2xxx/qla_target.c
> index 0d09480..c48daf5 100644
> --- a/drivers/scsi/qla2xxx/qla_target.c
> +++ b/drivers/scsi/qla2xxx/qla_target.c
> @@ -981,8 +981,7 @@ void qlt_free_session_done(struct work_struct *work)
> 			int rc;
> 
> 			if (!own ||
> -			    (own &&
> -			     (own->iocb.u.isp24.status_subcode == ELS_PLOGI))) {
> +			     (own->iocb.u.isp24.status_subcode == ELS_PLOGI)) {
> 				rc = qla2x00_post_async_logout_work(vha, sess,
> 				    NULL);
> 				if (rc != QLA_SUCCESS)
> -- 
> 1.8.3.1
> 

Looks Good. 

Reviewed-by: Himanshu Madhani <himanshu.madhani@xxxxxxxxxx>

--
Himanshu Madhani	 Oracle Linux Engineering





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux