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>] [day] [month] [year] [list]
Message-ID: <3ec2e7e0-cb21-f1ae-af6f-00eedc296235@canonical.com>
Date:   Tue, 28 Jan 2020 20:08:44 +0000
From:   Colin Ian King <colin.king@...onical.com>
To:     Chin-Yen Lee <timlee@...ltek.com>,
        Yan-Hsuan Chuang <yhchuang@...ltek.com>,
        Kalle Valo <kvalo@...eaurora.org>,
        "David S. Miller" <davem@...emloft.net>,
        "linux-wireless@...r.kernel.org" <linux-wireless@...r.kernel.org>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>
Cc:     "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: re: rtw88: support wowlan feature for 8822c

Hi

Static analysis with Coverity has found an issue with an uninitialized
variable in the following linux-next commit:

commit 44bc17f7f5b3b2cc4084eba6307ba750078a8a73
Author: Chin-Yen Lee <timlee@...ltek.com>
Date:   Thu Dec 19 16:58:14 2019 +0800

    rtw88: support wowlan feature for 8822c

Anaysis is as follows:

284 static bool rtw_wow_check_fw_status(struct rtw_dev *rtwdev, bool
wow_enable)
285 {

   1. var_decl: Declaring variable ret without initializer.
286        bool ret;
287
288        /* wait 100ms for wow firmware to finish work */
289        msleep(100);
290

   2. Condition wow_enable, taking true branch.
291        if (wow_enable) {

   3. Condition !rtw_read8(rtwdev, 455), taking false branch.
292                if (!rtw_read8(rtwdev, REG_WOWLAN_WAKE_REASON))
293                        ret = 0;

   4. Falling through to end of if statement.
294        } else {
295                if (rtw_read32_mask(rtwdev, REG_FE1IMR,
BIT_FS_RXDONE) == 0 &&
296                    rtw_read32_mask(rtwdev, REG_RXPKT_NUM,
BIT_RW_RELEASE) == 0)
297                        ret = 0;
298        }
299

Uninitialized scalar variable (UNINIT)5. uninit_use: Using uninitialized
value ret.

300        if (ret)
301                rtw_err(rtwdev, "failed to check wow status %s\n",
302                        wow_enable ? "enabled" : "disabled");
303
304        return ret;

Colin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ