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: <s5h1rivr0z1.wl-tiwai@suse.de>
Date:   Mon, 21 Sep 2020 10:24:50 +0200
From:   Takashi Iwai <tiwai@...e.de>
To:     trix@...hat.com
Cc:     perex@...ex.cz, tiwai@...e.com, natechancellor@...il.com,
        ndesaulniers@...gle.com, eblennerhassett@...ioscience.com,
        alsa-devel@...a-project.org, linux-kernel@...r.kernel.org,
        clang-built-linux@...glegroups.com
Subject: Re: [PATCH] ALSA: asihpi: fix iounmap in error handler

On Sun, 13 Sep 2020 18:52:30 +0200,
trix@...hat.com wrote:
> 
> From: Tom Rix <trix@...hat.com>
> 
> clang static analysis flags this problem
> hpioctl.c:513:7: warning: Branch condition evaluates to
>   a garbage value
>                 if (pci.ap_mem_base[idx]) {
>                     ^~~~~~~~~~~~~~~~~~~~
> 
> If there is a failure in the middle of the memory space loop,
> only some of the memory spaces need to be cleaned up.
> 
> At the error handler, idx holds the number of successful
> memory spaces mapped.  So rework the handler loop to use the
> old idx.
> 
> There is a second problem, the memory space loop conditionally
> iomaps()/sets the mem_base so it is necessay to initize pci.
> 
> Fixes: 719f82d3987a ("ALSA: Add support of AudioScience ASI boards")
> Signed-off-by: Tom Rix <trix@...hat.com>

Thanks, applied.


Takashi

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ