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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 23 Aug 2016 13:16:06 +0530
From:   Hariprasad Shenai <hariprasad@...lsio.com>
To:     Andrzej Hajda <a.hajda@...sung.com>
Cc:     "open list:CXGB4 ETHERNET DRIVER (CXGB4)" <netdev@...r.kernel.org>,
        Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>,
        Marek Szyprowski <m.szyprowski@...sung.com>,
        open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] cxgb4: fix invalid checks in alloc_uld_rxqs

On Tuesday, August 08/23/16, 2016 at 08:16:19 +0200, Andrzej Hajda wrote:
> Local variable msi_idx defined as unsigned int is always >= 0, thus both
> 'if' checks are always true. On the other side presence of USING_MSIX flag
> suggests the checks should not be trivially true.
> The simplest solution is to replace incorrect checks with direct testing
> of adap->flags and remove spare variables.
> 
> The problem has been detected using semantic patch
> scripts/coccinelle/tests/unsigned_lesser_than_zero.cocci
> 

The correct fix is to have local variable 'msi_idx' as int instead of unsigned
int. Thanks for reporting the issue. Do you want me to send a V2?

Thanks,
Hari

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ