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  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 15 May 2020 10:33:23 +0200
From:   Jerome Pouiller <>
        Greg Kroah-Hartman <>,
        Kalle Valo <>,
        "David S . Miller" <>,
        Jérôme Pouiller 
Subject: [PATCH 17/19] staging: wfx: remove false-positive WARN()

From: Jérôme Pouiller <>

The function wfx_tx_flush() wait for there is no more queued frames in
hardware queue. Then, for the sanity, it checks that there is no more
pending frame on any AC queue.

However, there is a race here. It may happens that hardware queues are
empty, but the counters of the AC queues are not yet updated. So, it may
produce false-positive warning.

The easiest way to solve the problem is just to remove the sanity check.

Signed-off-by: Jérôme Pouiller <>
 drivers/staging/wfx/queue.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/staging/wfx/queue.c b/drivers/staging/wfx/queue.c
index 0c799cedd101..26b141cbd303 100644
--- a/drivers/staging/wfx/queue.c
+++ b/drivers/staging/wfx/queue.c
@@ -30,7 +30,6 @@ void wfx_tx_unlock(struct wfx_dev *wdev)
 void wfx_tx_flush(struct wfx_dev *wdev)
 	int ret;
-	int i;
 	// Do not wait for any reply if chip is frozen
 	if (wdev->chip_frozen)
@@ -41,12 +40,6 @@ void wfx_tx_flush(struct wfx_dev *wdev)
 	ret = wait_event_timeout(wdev->hif.tx_buffers_empty,
-	if (ret) {
-		for (i = 0; i < IEEE80211_NUM_ACS; i++)
-			WARN(atomic_read(&wdev->tx_queue[i].pending_frames),
-			     "there are still %d pending frames on queue %d",
-			     atomic_read(&wdev->tx_queue[i].pending_frames), i);
-	}
 	if (!ret) {
 		dev_warn(wdev->dev, "cannot flush tx buffers (%d still busy)\n",

Powered by blists - more mailing lists